import Vue from 'vue'
import Router from 'vue-router'
import store from '@/store'
const _import = require('./_import_' + process.env.NODE_ENV)
import request from '@/utils/request'
Vue.use(Router)

import Layout from '@/views/layout/Layout'

export const constantRouterMap = [
  { path: '/404', component: _import('errorPage/404'), hidden: true },
  { path: '/login', component: _import('login/LoginPage'),hidden: true},
  {
    path: '/',
    component: Layout,
    hidden:true,
    meta: { title: '菜单1-title', icon: 'el-icon-message' },
    redirect: 'dashboard',
    children: [{
      path: 'dashboard',
      component: _import('index'),
      name: '首页',
      meta: { title: '首页', icon: 'el-icon-message' }
    }]
  }
];


export default new Router({
  routes: constantRouterMap
})


